#include <stdio.h>
void concatenate(char dest[], const char src1[], const char src2[]) {
    int i = 0, j = 0;
    while (src1[i] != '\0') {
        dest[i] = src1[i];
        i++;
    }
    while (src2[j] != '\0') {
        dest[i] = src2[j];
        i++;
        j++;
    }

    dest[i] = '\0';
}

int main() {
    char str1[] = "Hello, ";
    char str2[] = "World!";
    char result[100]; 
    for (int k = 0; k < 100; k++) {
        result[k] = '\0';
    }

    concatenate(result, str1, str2);

    printf("连接后的字符串: %s\n", result);

    return 0;
}